<template>
  <div class="advice">
    <el-table v-loading="loading" :data="tableData" border style="width: 100%">
      <el-table-column prop="phone" label="手机号" align="center">
      </el-table-column>
      <el-table-column prop="data" label="信息" align="center">
      </el-table-column>
      <el-table-column prop="time" label="时间" align="center">
      </el-table-column>
    </el-table>
  </div>
</template>
<script>
import {advices} from '@/api/api.js';

export default {
  data() {
    return {
      tableData: [],
      data: '',
      loading: false
    }
  },
  created() {
    this.getData();
  },
  methods: {
    getData(params) {
      advices(params)
          .then(res => {
            console.log(res.data);
            this.tableData = res.data.data;
          })
    }
  }

}

</script>
<style lang="scss" scoped>
.advice {

  margin-top: 20px;
}
</style>